The following image shows an overview of removing specific text from cells in Excel.

We have a dataset with 3 columns. We will remove specific string values from these cells based on various criteria.
We will remove the ending “-XYZ” string from Product Code cells.
Steps:
Select the data tableGo to the Home tab and select Editing.Choose Find & Select and click Find.Read More: How to Remove Letters from Cell in Excel
Method 2 – Removing Text from Cell with Flash FillWe will extract the product name before the dash and extract it in a separate Items column.
Steps:
Write down the part of the text you want to keep in Cell E5.Read More: How to Remove Text from an Excel Cell but Leave Numbers
Method 3 – Using the SUBSTITUTE Function to Remove Specific Text from CellsWe’ll remove the “-XYZ” part from Product Code cells and extract the rest in the Items column.
Steps:
Select Cell E5.Insert the following formula=SUBSTITUTE(B5,"-XYZ","")We’ll get the product names from the product code cells and put them in Items.
Steps:
Select Cell E5.Insert the following formula.=MID(B5,1,FIND("-",B5,1)-1)The FIND function finds the first dash in the B5 cell and returns its location. The MID function extracts the characters from the 1st character to that location from B5.
In the Color with Code column, we have some colors combined with their code number. We’ll remove the code and the dash.
Steps:
Select Cell E5.Use the following formula.=RIGHT(D5,LEN(D5)-FIND("-",D5,1))D5 is the text,LEN(D5) is the total length of the stringFIND("-", D5,1) will give the position of character “-” and then the value will be deducted from the total length of the string and it will be the number of characters for the RIGHT function.
Read More: How to Remove Text before a Space with Excel Formula
Method 6 – Applying the LEFT Function to Remove Text from CellsWe want to extract the Color Codes.
Steps:
Select Cell E5.Insert the following formula.=LEFT(D5,3)D5 is the text,3 is the number of characters you want to extract.
We’ll remove the color codes from the color section and insert the results in the added the Color column.
Steps:
Select Cell E5.Insert the following formula:=REPLACE(D5,1,4,"")D5 is the text,1 is the start number, 4 is the number of characters you want to replace with blank.
We want to remove the last three sizes in the Size column.
Steps:
Select the data table.Go to Home, then to Editing, choose Find & Select, and click on Replace.Read More: How to Remove Text After Character in Excel
Method 9 – Removing Multiple Characters Simultaneously with SUBSTITUTEWe want to remove all of the brackets separating colors in the Color with Code column and use “-” as a separator.
Steps:
Select Cell E5.Insert the following formula:=SUBSTITUTE(SUBSTITUTE(D5,"(","-"),")","")D5 is the text,SUBSTITUTE(D5,"(","-") here,“(” is the old text you want to replace with “-“.This output will be used by another SUBSTITUTE function.
We want to get only the last size instead of the 4 sizes in the Size column.
Steps:
Select Cell E5.Insert the following formula:=RIGHT(SUBSTITUTE(C5,",",CHAR(9),3),LEN(C5)-FIND(CHAR(9),SUBSTITUTE(C5,",",CHAR(9),3),1)+1)C5 is the text,SUBSTITUTE(C5,",", CHAR(9),3) here comma will be replaced by CHAR(9)(blank) and 3 is used to define the position of a comma before which I want to remove textsThe RIGHT function will give the output as the last size number from the right side.
Read More: How to Remove Everything After a Character in Excel
Method 11 – Removing Texts after the Nth Occurrence of a Specific Character Using LEFT and SUBSTITUTEWe’ll get only the first size.
Steps
Select Cell E5.Insert the following formula:=LEFT(SUBSTITUTE(C5,",",CHAR(9),1),FIND(CHAR(9),SUBSTITUTE(C5,",",CHAR(9),1),1)-1)C5 is the text,SUBSTITUTE(C5,",", CHAR(9),3) here comma will be replaced by CHAR(9)(blank) and 1 is used to define the position of a comma after which I want to remove textsThe LEFT function will give the output as the last size number from the left side.
Read More: How to Remove Text between Two Characters in Excel
Download the Excel Workbook
Remove Specific Text.xlsxSaveSavedRemoved 1
Tags: Excel Remove Text
Tanjima Hossainclass="mb10"> TANJIMA HOSSAIN is a marine engineer who enjoys working with Excel and VBA programming. For her, programming is a handy, time-saving tool for managing data, files, and online tasks. She's skilled in Rhino3D, Maxsurf C++, MS Office, AutoCAD, and Excel & VBA, going beyond the basics. She holds a B.Sc. in Naval Architecture & Marine Engineering from BUET and is now a content developer. In this role, she creates tech-focused content centred around Excel and VBA. Apart from... Read Full Bio
We will be happy to hear your thoughts Leave a reply Cancel reply














































